package com.ruoyi.project.service.impl;

import java.util.List;
import com.ruoyi.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.mapper.HeEventFlowMapper;
import com.ruoyi.project.domain.HeEventFlow;
import com.ruoyi.project.service.IHeEventFlowService;

/**
 * 事件流程Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-09-02
 */
@Service
public class HeEventFlowServiceImpl implements IHeEventFlowService 
{
    @Autowired
    private HeEventFlowMapper heEventFlowMapper;

    /**
     * 查询事件流程
     * 
     * @param id 事件流程主键
     * @return 事件流程
     */
    @Override
    public HeEventFlow selectHeEventFlowById(Long id)
    {
        return heEventFlowMapper.selectHeEventFlowById(id);
    }

    /**
     * 查询事件流程列表
     * 
     * @param heEventFlow 事件流程
     * @return 事件流程
     */
    @Override
    public List<HeEventFlow> selectHeEventFlowList(HeEventFlow heEventFlow)
    {
        return heEventFlowMapper.selectHeEventFlowList(heEventFlow);
    }

    /**
     * 新增事件流程
     * 
     * @param heEventFlow 事件流程
     * @return 结果
     */
    @Override
    public int insertHeEventFlow(HeEventFlow heEventFlow)
    {
        return heEventFlowMapper.insertHeEventFlow(heEventFlow);
    }

    /**
     * 修改事件流程
     * 
     * @param heEventFlow 事件流程
     * @return 结果
     */
    @Override
    public int updateHeEventFlow(HeEventFlow heEventFlow)
    {
        heEventFlow.setUpdateTime(DateUtils.getNowDate());
        return heEventFlowMapper.updateHeEventFlow(heEventFlow);
    }

    /**
     * 批量删除事件流程
     * 
     * @param ids 需要删除的事件流程主键
     * @return 结果
     */
    @Override
    public int deleteHeEventFlowByIds(Long[] ids)
    {
        return heEventFlowMapper.deleteHeEventFlowByIds(ids);
    }

    /**
     * 删除事件流程信息
     * 
     * @param id 事件流程主键
     * @return 结果
     */
    @Override
    public int deleteHeEventFlowById(Long id)
    {
        return heEventFlowMapper.deleteHeEventFlowById(id);
    }
}
